<template>
	<view class="notice_deta">
		<uv-navbar leftIcon="arrow-leftward" leftIconColor="#FFF" placeholder autoBack bgColor="#161714">
			<template v-slot:right>
				<view class="right_slot">
					<image src="@/static/images/6.png"></image>
				</view>
			</template>
		</uv-navbar>
		<view class="header">
			<view class="title">{{data_info.synopsis}}</view>
			<view class="other">
				<view class="name">{{data_info.title}}</view>
				<view class="time">{{data_info.created_at}}</view>
			</view>
		</view>
		<view class="content">
			<uv-parse :content="data_info.content"></uv-parse>
		</view>
	</view>
</template>

<script setup>
	import {
		newInfo
	} from "@/request/api";
	import {
		onLoad
	} from "@dcloudio/uni-app";
	import {
		ref
	} from "vue";

	const data_info = ref({});
	onLoad(async ({
		id
	}) => {
		let {
			info
		} = await newInfo({
			id
		});
		data_info.value = info;
	})
</script>

<style scoped lang="scss">
	.notice_deta {
		.right_slot {
			image {
				width: 24px;
				height: 24px;
			}
		}

		.header {
			border-bottom: 2px solid #2F2F2F;
			padding: 30rpx 40rpx;
			box-sizing: border-box;

			.title {
				line-height: 40rpx;
				color: #FFFFFF;
				font-size: 36rpx;
				font-weight: bold;
			}

			.other {
				padding-top: 80rpx;
				box-sizing: border-box;
				display: flex;
				justify-content: space-between;
				align-items: center;

				.name {
					color: #FFFFFF;
					font-size: 28rpx;
					font-weight: 800;
				}

				.time {
					color: #9198AB;
					font-size: 24rpx;
					font-family: DINPro;
				}
			}
		}

		.content {
			color: #999999;
			font-size: 26rpx;
			padding: 50rpx;
			box-sizing: border-box;
		}
	}
</style>